package com.ly.datacenter.pojo;

import java.util.ArrayList;
import java.util.Iterator;

/**
 * function：
 * @author watson  email: watson.wu@hotmail.com
 * @date 2009-9-6
 */
public class KeyValueList extends ArrayList<KeyValue> {

	private static final long serialVersionUID = 1L;

	/**
	 * function:
	 * @param key
	 * @return
	 */
	public boolean contains(String key) {
		Iterator<KeyValue> iterator = super.iterator();
		if(null != iterator)
			while(iterator.hasNext())
				if(iterator.next().getKey().equals(key))
					return true;
		return false;
	}

}

